home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / basic / expvbx10.zip / MATHEAPP.FRM < prev    next >
Text File  |  1995-03-16  |  5KB  |  147 lines

  1. VERSION 2.00
  2. Begin Form Form1 
  3.    Caption         =   "Form1"
  4.    ClientHeight    =   1845
  5.    ClientLeft      =   1095
  6.    ClientTop       =   1485
  7.    ClientWidth     =   3885
  8.    Height          =   2220
  9.    Left            =   1050
  10.    LinkTopic       =   "Form1"
  11.    ScaleHeight     =   1845
  12.    ScaleWidth      =   3885
  13.    Top             =   1155
  14.    Width           =   3975
  15.    Begin CommandButton Command2 
  16.       Caption         =   "Test dll file"
  17.       Height          =   375
  18.       Left            =   1920
  19.       TabIndex        =   8
  20.       Top             =   1320
  21.       Width           =   1455
  22.    End
  23.    Begin Expr Expr1 
  24.       IsNumExpr       =   0   'False
  25.       Left            =   3360
  26.       NumValue        =   0
  27.       StrInput        =   ""
  28.       StrLength       =   0
  29.       Top             =   840
  30.    End
  31.    Begin CommandButton Command1 
  32.       Caption         =   "Call Expr.vbx"
  33.       Height          =   375
  34.       Left            =   240
  35.       TabIndex        =   2
  36.       Top             =   1320
  37.       Width           =   1455
  38.    End
  39.    Begin TextBox Text1 
  40.       Height          =   285
  41.       Left            =   120
  42.       TabIndex        =   0
  43.       Text            =   "(123+sin(pi))*4^5*ln(exp(56))%11"
  44.       Top             =   150
  45.       Width           =   3015
  46.    End
  47.    Begin Label Label4 
  48.       FontBold        =   -1  'True
  49.       FontItalic      =   0   'False
  50.       FontName        =   "MS Sans Serif"
  51.       FontSize        =   9.75
  52.       FontStrikethru  =   0   'False
  53.       FontUnderline   =   0   'False
  54.       Height          =   255
  55.       Left            =   1800
  56.       TabIndex        =   7
  57.       Top             =   720
  58.       Width           =   615
  59.    End
  60.    Begin Label Label3 
  61.       Caption         =   "Is Numeric express?"
  62.       FontBold        =   -1  'True
  63.       FontItalic      =   0   'False
  64.       FontName        =   "MS Sans Serif"
  65.       FontSize        =   9.75
  66.       FontStrikethru  =   0   'False
  67.       FontUnderline   =   0   'False
  68.       Height          =   255
  69.       Left            =   120
  70.       TabIndex        =   6
  71.       Top             =   720
  72.       Width           =   1935
  73.    End
  74.    Begin Label Label1 
  75.       Caption         =   "Value is:"
  76.       FontBold        =   -1  'True
  77.       FontItalic      =   0   'False
  78.       FontName        =   "MS Sans Serif"
  79.       FontSize        =   9.75
  80.       FontStrikethru  =   0   'False
  81.       FontUnderline   =   0   'False
  82.       Height          =   255
  83.       Left            =   120
  84.       TabIndex        =   5
  85.       Top             =   480
  86.       Width           =   975
  87.    End
  88.    Begin Label Label2 
  89.       FontBold        =   -1  'True
  90.       FontItalic      =   0   'False
  91.       FontName        =   "MS Sans Serif"
  92.       FontSize        =   9.75
  93.       FontStrikethru  =   0   'False
  94.       FontUnderline   =   0   'False
  95.       Height          =   375
  96.       Left            =   1560
  97.       TabIndex        =   4
  98.       Top             =   480
  99.       Width           =   1815
  100.    End
  101.    Begin Label Label6 
  102.       FontBold        =   -1  'True
  103.       FontItalic      =   0   'False
  104.       FontName        =   "MS Sans Serif"
  105.       FontSize        =   9.75
  106.       FontStrikethru  =   0   'False
  107.       FontUnderline   =   0   'False
  108.       Height          =   315
  109.       Left            =   1800
  110.       TabIndex        =   3
  111.       Top             =   960
  112.       Width           =   795
  113.    End
  114.    Begin Label Label5 
  115.       Caption         =   "Length is:"
  116.       FontBold        =   -1  'True
  117.       FontItalic      =   0   'False
  118.       FontName        =   "MS Sans Serif"
  119.       FontSize        =   9.75
  120.       FontStrikethru  =   0   'False
  121.       FontUnderline   =   0   'False
  122.       Height          =   390
  123.       Left            =   120
  124.       TabIndex        =   1
  125.       Top             =   960
  126.       Width           =   1050
  127.    End
  128. End
  129. Declare Function chkexpr Lib "expr.dll" (ByVal S As String) As Integer
  130. Declare Function expres Lib "expr.dll" (ByVal S As String) As Double
  131.  
  132. Sub Command1_Click ()
  133.     Expr1.StrInput = text1.Text
  134.     Label6.Caption = Expr1.StrLength
  135. '    test vbx file
  136.     Label2.Caption = Expr1.NumValue
  137.     If Expr1.IsNumExpr Then Label4 = "True" Else Label4 = "False"
  138. End Sub
  139.  
  140. Sub Command2_Click ()
  141. '    test dll file
  142.     Label6.Caption = Len(text1)
  143.     Label2.Caption = expres(text1)
  144.     If Not chkexpr(text1) Then Label4 = "True" Else Label4 = "False"
  145. End Sub
  146.  
  147.